<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>


<body>
    <div id="test"></div>
</body>



<script type="text/javascript" src="../js/react.development.js"></script>
<script type="text/javascript" src="../js/react-dom.development.js"></script>
<script type="text/javascript" src="../js/babel.min.js"></script>


<script type="text/babel"> //必须声明 babel
    const myId = 'atGuigu'
    const myDate = 'react'
    // 创建虚拟 DOM 元素
    const vDom = (
        <h1 id={myId}>Hello {myDate}</h1>
    )
    // 渲染虚拟 DOM 到页面真实 DOM 容器中
    ReactDOM.render(vDom, document.getElementById('test'))
</script>

</html>